<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?>
<?php
	
	echo form_fieldset('ADMIN -- Ubah data kontestan ITBSPC 2011',array('class' => 'adminedit'));

	echo '<div id="column1">';
		echo form_open(('admin/spc_validasi/'.$userdata->spc_no_tim),array('class' => 'inline'));
		//$req= "<span id='req'> * </span>";
		$req = '';
		echo form_hidden('spc_no_tim',$userdata->spc_no_tim);
		echo '<h3>'.sprintf('SPC%03d',$userdata->spc_no_tim).'</h3>';
		echo form_label('Nama tim'.$req.'<span id="reg_rule"> minimal 4 karakter, maksimal 20 karakter.</span>','spc_nama_tim');
		echo form_error('spc_nama_tim');
		echo form_input('spc_nama_tim',
			(($this->input->post("spc_nama_tim")=='')?$userdata->spc_nama_tim:$this->input->post("spc_nama_tim")));
		
		echo form_label('Nama perguruan tinggi'.$req,'spc_nama_pt');
		echo form_error('spc_nama_pt');
		echo form_input('spc_nama_pt', 
			(($this->input->post("spc_nama_pt")=='')?$userdata->spc_nama_pt:$this->input->post("spc_nama_pt")));
		
		echo form_label('Alamat perguruan tinggi'.$req,'spc_alamat_pt');
		echo form_error('spc_alamat_pt');
		echo form_textarea('spc_alamat_pt', 
			(($this->input->post("spc_alamat_pt")=='')?$userdata->spc_alamat_pt:$this->input->post("spc_alamat_pt")));
		
		echo form_label('Nama lengkap anggota tim #1 (ketua tim)'.$req,'spc_nama_1');
		echo form_error('spc_nama_1');
		echo form_input('spc_nama_1',  
			(($this->input->post("spc_nama_1")=='')?$userdata->spc_nama_1:$this->input->post("spc_nama_1")));
		
		echo form_label('Nomor ponsel ketua tim'.$req,'spc_nohp');
		echo form_error('spc_nohp');
		echo form_input('spc_nohp',  
			(($this->input->post("spc_nohp")=='')?$userdata->spc_nohp:$this->input->post("spc_nohp")));
		
		echo form_label('Alamat email ketua tim'.$req,'spc_email');
		echo form_error('spc_email');
		echo form_input('spc_email',  
			(($this->input->post("spc_email")=='')?$userdata->spc_email:$this->input->post("spc_email")));
				
		echo form_label('Nama lengkap anggota tim #2','spc_nama_2');
		echo form_error('spc_nama_2');
		echo form_input('spc_nama_2',  
			(($this->input->post("spc_nama_2")=='')?$userdata->spc_nama_2:$this->input->post("spc_nama_2")));
		
		echo form_label('Nama lengkap anggota tim #3','spc_nama_3');
		echo form_error('spc_nama_3');
		echo form_input('spc_nama_3',  
			(($this->input->post("spc_nama_3")=='')?$userdata->spc_nama_3:$this->input->post("spc_nama_3")));
		
		echo form_label('Nama lengkap dosen pembimbing','spc_pembimbing');
		echo form_error('spc_pembimbing');
		echo form_input('spc_pembimbing', 
			(($this->input->post("spc_pembimbing")=='')?$userdata->spc_pembimbing:$this->input->post("spc_pembimbing")));
		

		echo '</div>';
		echo '<div id="column2">';

		echo form_fieldset('Ukuran Kaos',array('class' => 'passchange'));		
		$options = array(
				  ''	=> '-',
                  'S'  => 'S',
                  'M'    => 'M',
                  'ML'   => 'ML',
                  'L' => 'L',
                  'XL' => 'XL',
                  'XXL' => 'XXL',
                  'XXXL' => 'XXXL',
                );

		echo '<div class="center">';
		echo '<strong>Ukuran kaos #1 : </strong>';
		echo form_dropdown('spc_kaos_1', $options, $userdata->spc_kaos_1==''?'':$userdata->spc_kaos_1);
	
		echo '<br/><strong>Ukuran kaos #2 : </strong>';
		echo form_dropdown('spc_kaos_2', $options, $userdata->spc_kaos_2==''?'':$userdata->spc_kaos_2);
		
		echo '<br/><strong>Ukuran kaos #3 : </strong>';
		echo form_dropdown('spc_kaos_3', $options, $userdata->spc_kaos_3==''?'':$userdata->spc_kaos_3);
		echo '</div>';
			
		echo form_fieldset_close(); 

		echo form_fieldset('Syarat-syarat',array('class' => 'passchange'));
		echo form_label('KTM','spc_link_ktm1');
		echo 	'<ul><li>'.($userdata->spc_link_ktm1==''?'-':anchor_popup(base_url().$userdata->spc_link_ktm1,'link')).
				'</li><li>'.($userdata->spc_link_ktm2==''?'-':anchor_popup(base_url().$userdata->spc_link_ktm2,'link')).
				'</li><li>'.($userdata->spc_link_ktm3==''?'-':anchor_popup(base_url().$userdata->spc_link_ktm3,'link')).
				'</li></ul>';
		echo form_label('Bukti bayar','spc_link_buktibayar');
		echo 	'<ul><li>'.($userdata->spc_link_buktibayar==''?'-':anchor_popup(base_url().$userdata->spc_link_buktibayar,'link'))
				.'</li></ul>';
		
		$options = array(
               TRUE  => 'VALID',
               FALSE => 'TIDAK VALID',
        );

		echo 'Status Pendaftaran :<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;';
		echo form_dropdown('spc_valid', $options, $userdata->spc_valid==''?FALSE:$userdata->spc_valid);
		
		echo form_fieldset_close(); 	
		
		echo form_fieldset('Finalis',array('class' => 'passchange'));
		
		$options = array(
               TRUE  => 'Finalis',
               FALSE => 'Bukan Finalis',
        );

		echo 'Finalis :<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;';
		echo form_dropdown('spc_finalis', $options, $userdata->spc_valid==''?FALSE:$userdata->spc_finalis);
		
		echo form_fieldset_close(); 
			
	
		
		echo form_fieldset('Reset password (optional)',array('class' => 'passchange'));
		echo '<br/>';
		echo '<div class="center">';
		echo form_checkbox(array(
				'name'        => 'reset',
				'id'          => 'reset',
				'value'       => TRUE,
				'checked'     => FALSE,
				));
		echo ' Lakukan reset password.';
		echo '</div>';
		echo form_fieldset_close(); 
		
		
		echo '<br/>';
		echo form_submit(array(
				'name' => 'data_valid',
				//'class' => 'edit'
				)
				, 'Ubah data pendaftaran');
		echo form_close();
	
		echo form_open('admin/manage_spc',array('class' => 'inline'));
		echo form_submit(array(
				'name' => 'action',
				//'class' => 'button_n'
				)
				, 'Kembali');
		echo form_close();
		
		echo '</div>';
		echo form_fieldset_close(); 




